import java.util.Scanner;

public class Calc {

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		int first;
		int second;
		String operator;
		
		Calc c = new Calc();
		
		System.out.println("Input first value");
		Scanner scan = new Scanner(System.in);
		first = scan.nextInt();
		System.out.println("Input operator");
		operator = scan.next();
		System.out.println("Input second value");
		second = scan.nextInt();
		
//		System.out.println("first: " + first);
		System.out.println("operator: " + operator);
//		System.out.println("second: " + second);
		
		if (operator.charAt(0) == '+')
		{
			System.out.println("addition sum: " + c.addition(first,second));
		}
		
		else if (operator.charAt(0) == '-')
		{
			System.out.println("subtract sum: " + c.subtract(first,second));

		}

		else if (operator.charAt(0) == '*')
		{
			System.out.println("multiply sum: " + c.multiply(first,second));

		}
		
		else if (operator.charAt(0) == '/')
		{
			System.out.println("divide sum: " + c.divide(first,second));
		}
		else
		{
			System.out.println("Invalid operator was selected: " + operator);
		}
	}

	int addition(int val1, int val2)
	{
		int sum;
		
		sum =  val1 + val2;
		
		return sum;
	}
	
	int subtract(int val1, int val2)
	{
		int sum;
		
		sum = val1 - val2;
		
		return sum;
	}

	int multiply(int val1, int val2)
	{
		int sum;
		
		sum = val1 * val2;
		
		return sum;
	}

	double divide(double val1, double val2)
	{
		double sum;
		
		sum = (double) val1 / (double) val2;
		
		return sum;
	}
}